package com.hengby.hengcrud.modular.sys.mapper;

import com.hengby.hengcrud.modular.base.SuperMapper;
import com.hengby.hengcrud.modular.sys.model.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @author zhouheng
 */
public interface UserMapper extends SuperMapper<User> {

    /**
     * @param account
     * @return
     */
    User getUserByAccount(@Param("account") String account);

    List<User> findByLastName(String lastName);

    void save(User employee);

    List<Map<String, Object>> selectUsers(@Param("o") Object o, @Param("name") String name, @Param("beginTime") String beginTime, @Param("endTime") String endTime, @Param("deptid") Integer deptid);

    User getByACcount(@Param("account") String acount);

    /**
     * 修改用户状态
     */
    int setStatus(@Param("userId") Integer userId, @Param("status") Integer status);

}
